home *** CD-ROM | disk | FTP | other *** search
/ Apple WWDC 1996 / WWDC96_1996 (CD).toast / Technology Materials / MacOS 8 Resources / Developer Tools / Mac OS 8 Interfaces & Libraries / Interfaces / PInterfaces / KeyTranslation.p < prev    next >
Text File  |  1996-05-01  |  2KB  |  70 lines

  1. {
  2.      File:        KeyTranslation.p
  3.  
  4.      Version:    Technology:    System 8.0
  5.                  Release:    Universal Interfaces 3.0d3 on Copland DR1
  6.  
  7.      Copyright:    © 1984-1996 by Apple Computer, Inc.  All rights reserved.
  8.  
  9.      Bugs?:        If you find a problem with this file, send the file and version
  10.                  information (from above) and the problem description to:
  11.  
  12.                      Internet:    apple.bugs@applelink.apple.com
  13.                      AppleLink:    APPLE.BUGS
  14.  
  15. }
  16. {$IFC UNDEFINED UsingIncludes}
  17. {$SETC UsingIncludes := 0}
  18. {$ENDC}
  19.  
  20. {$IFC NOT UsingIncludes}
  21.  UNIT KeyTranslation;
  22.  INTERFACE
  23. {$ENDC}
  24.  
  25. {$IFC UNDEFINED __KEYTRANSLATION__}
  26. {$SETC __KEYTRANSLATION__ := 1}
  27.  
  28. {$I+}
  29. {$SETC KeyTranslationIncludes := UsingIncludes}
  30. {$SETC UsingIncludes := 1}
  31.  
  32. {$IFC UNDEFINED __KEYBOARD__}
  33. {$I Keyboard.p}
  34. {$ENDC}
  35. {$IFC UNDEFINED __LOCALEOBJECTS__}
  36. {$I LocaleObjects.p}
  37. {$ENDC}
  38. {$IFC UNDEFINED __TEXTINPUTSYSTEM__}
  39. {$I TextInputSystem.p}
  40. {$ENDC}
  41. {$IFC UNDEFINED __TYPES__}
  42. {$I Types.p}
  43. {$ENDC}
  44.  
  45. {$PUSH}
  46. {$ALIGN MAC68K}
  47. {$LibExport+}
  48.  
  49. {$IFC FOR_SYSTEM8_COOPERATIVE }
  50.  
  51. TYPE
  52.     KeyTranslationContextRef = ^LONGINT;
  53.     KeyTranslationObjectRef                = LocaleObjectRef;
  54. FUNCTION NewKeyTranslationContext(VAR contextRef: KeyTranslationContextRef; translationObject: KeyTranslationObjectRef): OSStatus; C;
  55. FUNCTION DisposeKeyTranslationContext(VAR contextRef: KeyTranslationContextRef): OSStatus; C;
  56. FUNCTION TranslateVirtualKeyCode(contextRef: KeyTranslationContextRef; keycode: ByteParameter; VAR character: UInt16): OSStatus; C;
  57. FUNCTION TranslateVirtualKeyCodeBuffer(contextRef: KeyTranslationContextRef; {CONST}VAR keycodeBuffer: VirtualKeyCode; keycodeBufferSize: UInt32; VAR characterBuffer: UInt16; characterBufferSize: UInt32): OSStatus; C;
  58. {$ENDC}
  59. {  FOR_SYSTEM8_COOPERATIVE }
  60. {$ALIGN RESET}
  61. {$POP}
  62.  
  63. {$SETC UsingIncludes := KeyTranslationIncludes}
  64.  
  65. {$ENDC} {__KEYTRANSLATION__}
  66.  
  67. {$IFC NOT UsingIncludes}
  68.  END.
  69. {$ENDC}
  70.